execute store result score #index temp run data get storage vs:system temp.index
execute store result storage vs:system temp.index int 1 run scoreboard players remove #index temp 1

execute if score #index temp matches ..-1 run return run function vs:chain/push/loop_break

scoreboard players reset #index temp

$schedule function vs:chain/push/next_command $(tick)t append